<?php
/*
	获取活动详情
*/
defined('BY_JYA') or exit('error');
list($params)=$arguments;
$code=pdo_get('jy_exchange_code',array('status'=>1,'groupid'=>$params['active_id'],'mid'=>$_SESSION['uid']));
pdo_update('jy_exchange_code',array('status'=>0),array('id'=>$code['id']));
pdo_update('jy_exchange_group',array('use +'=>1),array('id'=>$params['active_id']));
pdo_insert('jy_exchange_record',array('key'=>$code['key'],'mode'=>1,'mid'=>$_SESSION['uid'],'goods'=>$params['goods_id'],'time'=>time(),'ordersn'=>$params['ordersn'],'orderid'=>$params['order_id'],'uniacid'=>$_SESSION['uniacid']));
return $res;